package com.hkw.singlecityidpicker.areapickerview;

import android.content.Context;

import com.contrarywind.adapter.WheelAdapter;

import java.util.List;

public class ProvinceAdapter implements WheelAdapter<String> {

    Context context;
    List<AddressBean> addressBeans;

    public ProvinceAdapter(Context context, List<AddressBean> addressBeans) {
        this.context = context;
        this.addressBeans = addressBeans;
    }

    @Override
    public int getItemsCount() {
        return addressBeans.size();
    }

    @Override
    public String getItem(int index) {
        return addressBeans.get(index).getLabel();
    }

    @Override
    public int indexOf(String o) {
        return 0;
    }
}
